﻿<%@ Page Language="c#" Inherits="Discuz.Web.Admin.editadminusergroup" EnableViewState="true"
    CodeBehind="global_editadminusergroup.aspx.cs" %>

<%@ Register TagPrefix="cc1" Namespace="Discuz.Control" Assembly="Discuz.Control" %>
<%@ Register TagPrefix="cc3" Namespace="Discuz.Control" Assembly="Discuz.Control" %>
<%@ Register TagPrefix="uc1" TagName="UserGroupPowerSetting" Src="../UserControls/usergrouppowersetting.ascx" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<html>
<head>
    <title>编辑管理组</title>
    <link href="../styles/tab.css" type="text/css" rel="stylesheet" />
    <link href="../styles/colorpicker.css" type="text/css" rel="stylesheet" />
    <script type="text/javascript" src="../js/common.js"></script>
    <link href="../styles/dntmanager.css" type="text/css" rel="stylesheet" />
    <link href="../styles/modelpopup.css" type="text/css" rel="stylesheet" />
    <script type="text/javascript" src="../js/modalpopup.js"></script>
    <script type="text/javascript">
        function validate(theform) {
            if (validatebonusprice()) {
                document.getElementById("TabControl1_tabPage51_radminid").disabled = false;
                return true;
            }
            else {
                return false;
            }
        }
        function resetPage() {
            document.getElementById('success').style.display = 'none'
            document.getElementById("UpdateUserGroupInf").disabled = false;
        }
        function setatatus(obj) {
            if (obj.id == "TabControl1_tabPage33_admingroupright_3") {
                if (document.getElementById("TabControl1_tabPage33_admingroupright_3").checked == true) {
                    document.getElementById("TabControl1_tabPage33_admingroupright_2").checked = true;
                }
            }
            if (obj.id == "TabControl1_tabPage33_admingroupright_2") {
                if (document.getElementById("TabControl1_tabPage33_admingroupright_2").checked == false) {
                    document.getElementById("TabControl1_tabPage33_admingroupright_3").checked = false;
                }
            }
        }
    </script>
    <meta http-equiv="X-UA-Compatible" content="IE=7" />
</head>
<body>
    <div class="ManagerForm">
        <form id="Form1" method="post" runat="server">
        <cc3:TabControl ID="TabControl1" SelectionMode="Client" runat="server" TabScriptPath="../js/tabstrip.js"
            Width="660" Height="100%">
            <cc3:TabPage Caption="基本信息" ID="tabPage51">
                <table width="100%">
                    <tr>
                        <td class="item_title" colspan="2">
                            用户组名称
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop rowform">
                            <cc1:TextBox ID="groupTitle" runat="server" CanBeNull="必填" RequiredFieldType="暂无校验"
                                MaxLength="50">
                            </cc1:TextBox>
                        </td>
                        <td class="vtop">
                        </td>
                    </tr>
                    <tr>
                        <td class="item_title" colspan="2">
                            关联管理组
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop rowform">
                            <cc1:DropDownList ID="radminid" runat="server" AutoPostBack="True">
                            </cc1:DropDownList>
                        </td>
                        <td class="vtop">
                        </td>
                    </tr>
                    <tr>
                        <td class="item_title" colspan="2">
                            组名称颜色
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop rowform">
                            <cc1:ColorPicker ID="color" runat="server" ReadOnly="True" LeftOffSet="-23" TopOffSet="-54">
                            </cc1:ColorPicker>
                        </td>
                        <td class="vtop">
                            用户组名称的显示颜色
                        </td>
                    </tr>
                    <tr>
                        <td class="item_title" colspan="2">
                            星星数
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop rowform">
                            <cc1:TextBox ID="stars" runat="server" CanBeNull="必填" RequiredFieldType="数据校验" Text="0"
                                Size="5" MaxLength="4">
                            </cc1:TextBox>
                            <asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="SERVER" ControlToValidate="stars"
                                ErrorMessage="请输入正整数或者零" ValidationExpression="^[0-9]*$">
                            </asp:RegularExpressionValidator>
                        </td>
                        <td class="vtop">
                            该用户组显示的星星数
                        </td>
                    </tr>
                    <tr>
                        <td class="item_title" colspan="2">
                            阅读权限
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop rowform">
                            <cc1:TextBox ID="readaccess" runat="server" CanBeNull="必填" RequiredFieldType="数据校验"
                                Size="5" MaxLength="4">
                            </cc1:TextBox>
                            <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="SERVER" ControlToValidate="readaccess"
                                ErrorMessage="请输入整数" ValidationExpression="^[-]?\d+\d*$">
                            </asp:RegularExpressionValidator>
                        </td>
                        <td class="vtop">
                            设置用户浏览帖子或附件的权限级别,范围 0~255,0 为禁止用户浏览任何帖子或附件.当用户的阅读权限小于帖子或附件的阅读权限许可(默认时为 1)时,用户将不能阅读该帖子或下载该附件
                        </td>
                    </tr>
                    <tr>
                        <td class="item_title" colspan="2">
                            短消息最多条数
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop rowform">
                            <cc1:TextBox ID="maxpmnum" runat="server" CanBeNull="必填" RequiredFieldType="数据校验"
                                Text="0" Size="5" MaxLength="4">
                            </cc1:TextBox>
                            <asp:RegularExpressionValidator ID="homephone" runat="SERVER" ControlToValidate="maxpmnum"
                                ErrorMessage="请输入正整数或者零" ValidationExpression="^[0-9]*$">
                            </asp:RegularExpressionValidator>
                        </td>
                        <td class="vtop">
                            设置用户短消息最大可保存的消息数目,0 为禁止使用短消息
                        </td>
                    </tr>
                    <tr>
                        <td class="item_title" colspan="2">
                            主题(附件)最高售价
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop rowform">
                            <cc1:TextBox ID="maxprice" runat="server" CanBeNull="必填" RequiredFieldType="数据校验"
                                Text="0" Size="5" MaxLength="4">
                            </cc1:TextBox>
                            <asp:RegularExpressionValidator ID="RegularExpressionValidator3" runat="SERVER" ControlToValidate="maxprice"
                                ErrorMessage="请输入正整数或者零" ValidationExpression="^[0-9]*$">
                            </asp:RegularExpressionValidator>
                        </td>
                        <td class="vtop">
                            主题(附件)出售使得作者可以将自己发表的主题(附件)隐藏起来,只有当浏览者向作者支付相应的交易积分后才能查看主题(附件)内容.此处设置用户出售主题(附件)时允许设置的最高价格,0
                            为不允许用户出售.
                        </td>
                    </tr>
                    <tr>
                        <td class="item_title" colspan="2">
                            上传单个附件允许的最大字节数
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop rowform">
                            <cc1:TextBox ID="maxattachsize" runat="server" CanBeNull="必填" RequiredFieldType="数据校验"
                                Text="0" Size="10" MaxLength="9">
                            </cc1:TextBox>(单位:字节)
                            <select onchange="document.getElementById('TabControl1_tabPage51_maxattachsize').value=this.value">
                                <option value="">请选择</option>
                                <option value="1048576">1M</option>
                                <option value="2097152">2M</option>
                                <option value="4194304">4M</option>
                                <option value="10485760">10M</option>
                                <option value="20971520">20M</option>
                                <option value="31457280">30M</option>
                                <option value="52428800">50M</option>
                                <option value="83886090">80M</option>
                                <option value="104857600">100M</option>
                                <option value="209715200">200M</option>
                                <option value="314572800">300M</option>
                                <option value="419430400">400M</option>
                                <option value="524288000">500M</option>
                            </select>
                        </td>
                        <td class="vtop">
                            设置上传单个附件允许最大字节数
                        </td>
                    </tr>
                    <tr>
                        <td class="item_title" colspan="2">
                            论坛每天允许上传附件总字节数
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop rowform">
                            <cc1:TextBox ID="maxsizeperday" runat="server" CanBeNull="必填" RequiredFieldType="数据校验"
                                Text="0" Size="10" MaxLength="9">
                            </cc1:TextBox>(单位:字节)
                            <select onchange="document.getElementById('TabControl1_tabPage51_maxsizeperday').value=this.value">
                                <option value="">请选择</option>
                                <option value="1048576">1M</option>
                                <option value="2097152">2M</option>
                                <option value="4194304">4M</option>
                                <option value="10485760">10M</option>
                                <option value="20971520">20M</option>
                                <option value="31457280">30M</option>
                                <option value="52428800">50M</option>
                                <option value="83886090">80M</option>
                                <option value="104857600">100M</option>
                                <option value="209715200">200M</option>
                                <option value="314572800">300M</option>
                                <option value="419430400">400M</option>
                                <option value="524288000">500M</option>
                                <option value="629145600">600M</option>
                                <option value="734003200">700M</option>
                                <option value="838860900">800M</option>
                                <option value="943718400">900M</option>
                                <option value="1048576000">1000M</option>
                            </select>
                        </td>
                        <td class="vtop">
                            设置用户每 24 小时可以上传的附件总字节数.注意: 本功能会加重服务器负担,建议仅在必要时使用.
                        </td>
                    </tr>
                    <tbody <%=haveSpace?"":" style='display:none'"%>>
                        <tr>
                            <td class="item_title" colspan="2">
                                个人空间附件总字节数
                            </td>
                        </tr>
                        <tr>
                            <td class="vtop rowform">
                                <cc1:TextBox ID="maxspaceattachsize" runat="server" CanBeNull="必填" RequiredFieldType="数据校验"
                                    Text="0" Size="10" MaxLength="9">
                                </cc1:TextBox>(单位:字节)
                                <select onchange="document.getElementById('TabControl1_tabPage51_maxspaceattachsize').value=this.value">
                                    <option value="">请选择</option>
                                    <option value="1048576">1M</option>
                                    <option value="2097152">2M</option>
                                    <option value="4194304">4M</option>
                                    <option value="10485760">10M</option>
                                    <option value="20971520">20M</option>
                                    <option value="31457280">30M</option>
                                    <option value="52428800">50M</option>
                                    <option value="83886090">80M</option>
                                    <option value="104857600">100M</option>
                                    <option value="209715200">200M</option>
                                    <option value="314572800">300M</option>
                                    <option value="419430400">400M</option>
                                    <option value="524288000">500M</option>
                                    <option value="629145600">600M</option>
                                    <option value="734003200">700M</option>
                                    <option value="838860900">800M</option>
                                    <option value="943718400">900M</option>
                                    <option value="1048576000">1000M</option>
                                </select>
                            </td>
                            <td class="vtop">
                                设置用户在个人空间中可以上传附件的字节总数.
                            </td>
                        </tr>
                    </tbody>
                    <tbody <%=haveAlbum?"":" style='display:none'"%>>
                        <tr>
                            <td class="item_title" colspan="2">
                                主题(附件)最高售价
                            </td>
                        </tr>
                        <tr>
                            <td class="vtop rowform">
                                <cc1:TextBox ID="maxspacephotosize" runat="server" CanBeNull="必填" RequiredFieldType="数据校验"
                                    Text="0" Size="10" MaxLength="9">
                                </cc1:TextBox>(单位:字节)
                                <select onchange="document.getElementById('TabControl1_tabPage51_maxspacephotosize').value=this.value">
                                    <option value="">请选择</option>
                                    <option value="1048576">1M</option>
                                    <option value="2097152">2M</option>
                                    <option value="4194304">4M</option>
                                    <option value="10485760">10M</option>
                                    <option value="20971520">20M</option>
                                    <option value="31457280">30M</option>
                                    <option value="52428800">50M</option>
                                    <option value="83886090">80M</option>
                                    <option value="104857600">100M</option>
                                    <option value="209715200">200M</option>
                                    <option value="314572800">300M</option>
                                    <option value="419430400">400M</option>
                                    <option value="524288000">500M</option>
                                    <option value="629145600">600M</option>
                                    <option value="734003200">700M</option>
                                    <option value="838860900">800M</option>
                                    <option value="943718400">900M</option>
                                    <option value="1048576000">1000M</option>
                                </select>
                            </td>
                            <td class="vtop">
                                设置用户在相册中可以上传照片的字节总数.
                            </td>
                        </tr>
                    </tbody>
                    <tr>
                        <td class="item_title" colspan="2">
                            允许附件类型
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop rowform">
                            <cc1:CheckBoxList ID="attachextensions" runat="server" HintHeight="80" RepeatColumns="3">
                            </cc1:CheckBoxList>
                        </td>
                        <td class="vtop">
                            如果要允许所有附件类型, 则不要点选右侧任何附件类型, 且具体版块设置优先于用户组设置.
                        </td>
                    </tr>
                    <tr>
                        <td class="item_title" colspan="2">
                            签名最多字节
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop rowform">
                            <cc1:TextBox ID="maxsigsize" runat="server" CanBeNull="必填" RequiredFieldType="数据校验"
                                Text="0" Size="5" MaxLength="4">
                            </cc1:TextBox>
                            <asp:RegularExpressionValidator ID="RegularExpressionValidator4" runat="SERVER" ControlToValidate="maxsigsize"
                                ErrorMessage="请输入正整数或者零" ValidationExpression="^[0-9]*$">
                            </asp:RegularExpressionValidator>
                        </td>
                        <td class="vtop">
                            设置用户签名最大字节数,0 为不允许用户使用签名.
                        </td>
                    </tr>
                    <tr>
                        <td class="item_title" colspan="2">
                            允许的评分范围
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop rowform">
                            <a href="#" class="TextButton" onclick="javascript:window.location.href='global_allowparticipatescore.aspx?pagename=global_editadminusergroup&groupid=<%=Request.Params["groupid"]%>'">
                                编辑评分范围</a>
                        </td>
                        <td class="vtop">
                        </td>
                    </tr>
                </table>
            </cc3:TabPage>
            <cc3:TabPage Caption="权限信息" ID="tabPage22">
                <uc1:UserGroupPowerSetting ID="usergrouppowersetting" runat="server" />
            </cc3:TabPage>
            <cc3:TabPage Caption="管理权限设置" ID="tabPage33">
                <table width="100%">
                    <tr>
                        <td class="item_title" colspan="2">
                            操作权限设置
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop" colspan="2">
                            <cc1:CheckBoxList ID="admingroupright" runat="server" Width="500px" Font-Size="12px">
                                <asp:ListItem Value="alloweditpost">允许编辑帖子</asp:ListItem>
                                <asp:ListItem Value="alloweditpoll">允许编辑投票</asp:ListItem>
                                <asp:ListItem onClick="setatatus(this)" Value="allowdelpost">允许删除帖子</asp:ListItem>
                                <asp:ListItem onClick="setatatus(this)" Value="allowmassprune">允许批量删除</asp:ListItem>
                                <asp:ListItem Value="allowviewip">允许查看IP</asp:ListItem>
                                <asp:ListItem Value="allowedituser">允许编辑用户</asp:ListItem>
                                <asp:ListItem Value="allowviewlog">允许查看论坛运行记录</asp:ListItem>
                                <asp:ListItem Value="disablepostctrl">发帖不受审核、过滤、灌水等限制</asp:ListItem>
                                <asp:ListItem Value="allowviewrealname">允许查看用户实名</asp:ListItem>
                                <asp:ListItem Value="allowbanuser">允许禁止用户</asp:ListItem>
                                <asp:ListItem Value="allowbanip">允许禁止IP</asp:ListItem>
                                <asp:ListItem Value="allowmodpost">允许审核帖</asp:ListItem>
                                <asp:ListItem Value="allowpostannounce">允许发布公告</asp:ListItem>
                                <asp:ListItem Value="allowreportusergroup">是否允许接收举报信息</asp:ListItem>
                                <asp:ListItem Value="allowphotomangegroupsp">是否允许管理图片评论</asp:ListItem>
                            </cc1:CheckBoxList>
                        </td>
                    </tr>
                    <tr>
                        <td class="item_title" colspan="2">
                            是否允许置顶
                        </td>
                    </tr>
                    <tr>
                        <td class="vtop rowform">
                            <cc1:DropDownList ID="allowstickthread" runat="server">
                                <asp:ListItem Value="0">不允许</asp:ListItem>
                                <asp:ListItem Value="1">允许本版内置顶</asp:ListItem>
                                <asp:ListItem Value="2">允许分类内置顶</asp:ListItem>
                                <asp:ListItem Value="3">执行任意置顶</asp:ListItem>
                            </cc1:DropDownList>
                        </td>
                        <td class="vtop">
                        </td>
                    </tr>
                </table>
            </cc3:TabPage>
        </cc3:TabControl>
        <cc1:Hint ID="Hint1" runat="server" HintImageUrl="../images">
        </cc1:Hint>
        <div class="Navbutton">
            <cc1:Button ID="UpdateUserGroupInf" runat="server" Text=" 提 交 " ValidateForm="true">
            </cc1:Button>&nbsp;&nbsp;
            <cc1:Button ID="DeleteUserGroupInf" runat="server" Text=" 删 除 " ButtonImgUrl="../images/del.gif">
            </cc1:Button>&nbsp;&nbsp;
            <button type="button" class="ManagerButton" id="Button3" onclick="window.history.back();">
                <img src="../images/arrow_undo.gif" />
                返 回
            </button>
        </div>
        <div id="topictypes" style="display: none;">
            <tr>
                <td class="item_title" colspan="2">
                    积分下限
                </td>
            </tr>
            <tr>
                <td class="vtop rowform">
                    <cc1:TextBox ID="creditshigher" runat="server" CanBeNull="必填" RequiredFieldType="数据校验"
                        Text="0" Width="100">
                    </cc1:TextBox>
                </td>
                <td class="vtop">
                </td>
            </tr>
            <tr>
                <td class="item_title" colspan="2">
                    积分上限
                </td>
            </tr>
            <tr>
                <td class="vtop rowform">
                    <cc1:TextBox ID="creditslower" runat="server" CanBeNull="必填" RequiredFieldType="数据校验"
                        Text="0" Width="100">
                    </cc1:TextBox>
                </td>
                <td class="vtop">
                </td>
            </tr>
            <tr>
                <td class="item_title" colspan="2">
                    用户组头像
                </td>
            </tr>
            <tr>
                <td class="vtop rowform">
                    <cc1:TextBox ID="groupavatar" runat="server" RequiredFieldType="暂无校验" Width="80%">
                    </cc1:TextBox>
                </td>
                <td class="vtop">
                </td>
            </tr>
        </div>
        </form>
    </div>
    <%=footer%>
</body>
</html>
